import request from '@/utils/request'

export const queryStuAllApi = (name, degree, clazzId, page, pageSize) =>
  request.get(`/students?name=${name}&degree=${degree}&clazzId=${clazzId}&page=${page}&pageSize=${pageSize}`)

//新增
export const addStuApi = (stu) => request.post('/students', stu)
//修改
export const updateStuApi = (stu) => request.put('/students', stu)
//根据id查询
export const queryStuByIdApi = (id) => request.get(`/students/${id}`)
//删除
export const deleteStuApi = (ids) =>  request.delete(`/students/${ids}`);
//违纪
export const addDisciplineApi = (id,score) => request.put(`/students/violation/${id}/${score}`)